API Documentation
Static Public Member Functions | List of all members
nkWinUi::AlignmentUtils Class Referencefinal

Holds static utility functions to interact with the ALIGNMENT enum class values. More...

Static Public Member Functions

static nkMemory::StringView enumToString (ALIGNMENT toConvert)
 
static ALIGNMENT stringToEnum (const nkMemory::StringView &toConvert)
 

Detailed Description

Holds static utility functions to interact with the ALIGNMENT enum class values.

Member Function Documentation

◆ enumToString()

static nkMemory::StringView nkWinUi::AlignmentUtils::enumToString ( ALIGNMENT  toConvert)
static

Converts an ALIGNMENT value to a string representation. Value range is :

Enum value String value
ALIGNMENT::LEFT_TOP 'LEFT_TOP'
ALIGNMENT::CENTER 'CENTER'
ALIGNMENT::RIGHT_BOTTOM 'RIGHT_BOTTOM'
Parameters
toConvertThe value to convert to a string.
Returns
The value represented as a string.

◆ stringToEnum()

static ALIGNMENT nkWinUi::AlignmentUtils::stringToEnum ( const nkMemory::StringView toConvert)
static

Converts a string to an ALIGNMENT value. Value range is :

String value Enum value
'LEFT_TOP' ALIGNMENT::LEFT_TOP
'CENTER' ALIGNMENT::CENTER
'RIGHT_BOTTOM' / Anything else ALIGNMENT::RIGHT_BOTTOM'
Parameters
toConvertThe string to convert.
Returns
The value of ALIGNMENT the strings translates into. Defaults to ALIGNMENT::RIGHT_BOTTOM if the string has no translation attached.

The documentation for this class was generated from the following file: